home *** CD-ROM | disk | FTP | other *** search
/ CU Amiga Super CD-ROM 6 / CU Amiga Magazine's Super CD-ROM 06 (1996)(EMAP Images)(GB)(Track 1 of 4)[!][issue 1997-01].iso / cucd / graphics / whirlgif201 / src.original / whirlgif.h < prev   
C/C++ Source or Header  |  1996-11-01  |  2KB  |  122 lines

  1.  
  2. /*
  3.  * whirlgif.h
  4.  *
  5.  * Copyright (C) 1995,1996 by Kevin Kadow
  6.  * Copyright (C) 1990,1991,1992 by Mark Podlipec. 
  7.  * All rights reserved.
  8.  *
  9.  * This software may be freely copied, modified and redistributed
  10.  * without fee provided that this copyright notice is preserved 
  11.  * intact on all copies and modified copies.
  12.  * 
  13.  * There is no warranty or other guarantee of fitness of this software.
  14.  * It is provided solely "as is". The author(s) disclaim(s) all
  15.  * responsibility and liability with respect to this software's usage
  16.  * or its effect upon hardware or computer systems.
  17.  *
  18.  */
  19.  
  20. /* Default amount of inter-frame time */
  21. #define DEFAULT_TIME 10
  22. /* If set to 1, Netscape 'loop' code will be added by default */
  23. #define DEFAULT_LOOP 0
  24. /* If set to 1, use the colormaps from all images, not just the first */
  25. #define DEFAULT_USE_COLORMAP 0
  26.  
  27. #include <stdio.h>
  28.  
  29.  
  30. #define BIGSTRING 256
  31. #define LONG int
  32. #define ULONG unsigned int
  33. #define BYTE char
  34. #define UBYTE unsigned char
  35. #define SHORT short
  36. #define USHORT unsigned short
  37. #define WORD short int
  38. #define UWORD unsigned short int
  39.  
  40. #ifndef TRUE
  41. #define TRUE 1
  42. #endif
  43. #ifndef FALSE
  44. #define FALSE 0
  45. #endif
  46.  
  47. /* Used in calculating the transparent color */
  48. #define TRANS_NONE 1
  49. #define TRANS_RGB 2
  50. #define TRANS_MAP 3
  51.  
  52. #define DISP_NONE 0
  53. #define DISP_NOT  1
  54. #define DISP_BACK 2
  55. #define DISP_PREV 4
  56. /* set default disposal method here to any of the DISP_XXXX values */
  57. #define DEFAULT_DISPOSAL DISP_NONE
  58.  
  59. typedef struct
  60. {
  61.  int type;
  62.  UBYTE valid;
  63.  UBYTE map;
  64.  UBYTE red;
  65.  UBYTE green;
  66.  UBYTE blue;
  67.  } Transparency;
  68.  
  69. typedef struct
  70. {
  71.  Transparency trans;
  72.  int left;
  73.  int top;
  74.  unsigned int time;
  75.  unsigned short disposal;
  76. } Global;
  77.  
  78. typedef struct
  79. {
  80.  int width;
  81.  int height;
  82.  UBYTE m;
  83.  UBYTE cres;
  84.  UBYTE pixbits;
  85.  UBYTE bc;
  86. } GIF_Screen_Hdr; 
  87.  
  88. typedef union 
  89. {
  90.  struct
  91.  {
  92.   UBYTE red;
  93.   UBYTE green;
  94.   UBYTE blue;
  95.   UBYTE pad;
  96.  } cmap;
  97.  ULONG pixel;
  98. } GIF_Color;
  99.  
  100. typedef struct
  101. {
  102.  int left;
  103.  int top;
  104.  int width;
  105.  int height;
  106.  UBYTE m;
  107.  UBYTE i;
  108.  UBYTE pixbits;
  109.  UBYTE reserved;
  110. } GIF_Image_Hdr;
  111.  
  112. typedef struct 
  113. {
  114.  UBYTE valid;
  115.  UBYTE data;
  116.  UBYTE first;
  117.  UBYTE res;
  118.  int last;
  119. } GIF_Table;
  120.  
  121.  
  122.